<template>
    <div>
        <h3>用户列表(默认插槽实现的)</h3>
        <ul>
            <li v-for="value in source" :key="value.id">
                <slot :user="value"></slot>
            </li>
        </ul>
    </div>
</template>

<script setup>
import { ref,defineProps } from 'vue'
const source = ref([
    {id:1, name: '张三', age: 18},
    {id:2, name: 'wangwu', age: 18},
    {id:3, name: 'lisi', age: 18},
])


</script>

<style>
    
</style>